<?php

namespace app\logic;

use app\model\FlowSet as FlowSetModel;

class FlowSetLogic
{
    private FlowSetModel $flowSetModel;

    /**
     * @param FlowSetModel $flowSetModel
     */
    public function __construct(FlowSetModel $flowSetModel)
    {
        $this->flowSetModel = $flowSetModel;
    }

    /**
     * @param string $num
     * @return mixed
     */
    public function getMid(string $num): mixed
    {
        return $this->flowSetModel->where('num', $num)->value('id');
    }
}